package com.cdy.store.repository;

import com.cdy.common.domain.FileEntity;
import com.cdy.common.domain.FileSectionEntity;

import java.util.List;

/**
 * 文件持久化层接口
 *
 * Created by 陈东一
 * 2019/10/19 0019 15:46
 */
public interface FileRepository {
    
    
    FileEntity getFileByFileMd5(String md5);

    FileEntity getFileById(Long id);

    List<FileSectionEntity> listTaskByFileId(Long fileId);
    
    void insertFileSectionList(Long fileId, List<FileSectionEntity> list);
    
    void insertFile(FileEntity fileEntity);
    
    FileSectionEntity getTaskByIdAndFileId(Long id, Long fileId);

    FileSectionEntity getTaskById(Long id);

    void updateTaskById(FileSectionEntity fileSectionEntity);

    void updateFileByMD5(FileEntity fileEntity);

    
}
